from MyTelloLib.TelloCV import TelloCV
from MyTelloLib.MyTello import MyTello

tello=MyTello('192.168.10.2')
telloCV=TelloCV(tello)
telloCV.init_hand_tracker()

while True:
    frame = tello.get_video_frame()
    if frame is not None:
        leftOrRight, shoushi, image = telloCV.hand_detect(frame)
        telloCV.cmd_control(leftOrRight, shoushi,30)
        if telloCV.show(image):
            break
        
del telloCV
tello.quit()
del tello